<template>
  <div class="left_container">
    <search-bar @query_click="handleQueryClick" @reset_click="handleResetClick" />
    <pagination-table ref="pagination_table"  @click_create_reception="handleReceprion" />
  </div>
</template>

<script>
import SearchBar from './search-bar'
import PaginationTable from './pagination-table'
export default {
  name: 'ItemList',
  components: {
    SearchBar,
    PaginationTable,
  },
  data() {
    return {
      activeName:'left'
    }
  },
  methods: {
    /** 搜索栏组件事件处理----------------------------------------------------------- */
    /** 点击查询栏【查询】按钮 */
    handleQueryClick(queryParams) {
      this.$refs['pagination_table'].handleQuery(queryParams)
    },
    /** 点击查询栏【重置】按钮 */
    handleResetClick() {
      this.$refs['pagination_table'].handleQuery(null)
    },
    /** 操作栏组件的事件处理 -----------------------------------------------------------*/
    // 传递子级id给父级tab标签，打开详情页
    handleReceprion(id){
      this.$emit('click_create_receptiondate',id)
    }
  }
}
</script>
<style lang="scss" scoped>
.left_container{
  padding: 0;
}
</style>
